package com.woniuxy.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.woniuxy.pojo.User;
import com.woniuxy.pojo.dto.*;
import org.springframework.http.ResponseEntity;

import java.util.List;

/**
 *
 */
public interface UserService extends IService<User> {

    ResponseEntity login(LoginDTO dto);

    User findTel(String telephone);

    boolean emailExists(String email);

    User findEmail(String email);

    User createNewAccount(RegisterDTO dto);

    boolean accountExists(String account);

    boolean phoneExists(String phone);

    Boolean moveAccount(Integer id);

    Boolean batchRemove(List<Integer> ids);

    Boolean saveChangeUser(Integer userId, UserDTO dto);

    Boolean addAccount(UserDTO dto);

    Boolean removePreUser(Integer id);

    Boolean batchRemPreUser(List<Integer> ids);

    List<RegionUserCountDTO> getUserCountByRegion();

    GenderStatisticsDTO getGenderStatistics();

    List<AgeDistributionDTO> getAgeDistributionWithPercentage();

}
